<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>绑定属性</title>
    <style>
        .my{
            border: 1px solid red;
        }
    </style>
</head>
<body>

<div id="div">
    <a v-bind:href="url">百度一下</a>
<br>
    <a :href="url">百度一下</a>
    <br>
    <div :class="cls">我是div</div>

</div>



</body>
<script src="../js/vue.js"></script>
<script>
new Vue({
    el:"#div",
    data:{
        url:"https://www.baidu.com",
        cls:"my"
    }
});
</script>
</html>